#ifndef INET_SELECTOR_REACTOR_H
#define INET_SELECTOR_REACTOR_H

#include "EventHandler.h"
#include "EventTypes.h"
#include "DemuxTable.h"
#include "ReactorImplementation.h"

#include <sys/select.h>
#include <iostream>
#include <cerrno>

class SelectorReactor : public ReactorImplementation
{
 public:
  void registerHandler(EventHandler * eh, EventType et);
  void removeHandler(EventHandler * eh, EventType et);
  void handleEvents(timeval * timeout = 0);

 private:
  DemuxTable demuxer_;
};

#endif

